package cn.com.jinhao.hotline.commons.base.oracle;

import lombok.Data;
import tk.mybatis.mapper.annotation.KeySql;
import tk.mybatis.mapper.code.ORDER;

import javax.persistence.Column;
import javax.persistence.Id;


/**
 * HotLine
 * <p>Description: 基础实体类    包括主键ID和分页属性</p>
 *
 * @author ShaneMew
 * @version 1.0
 * @date 2019/10/11
 * @since 2019-10-11
 */
@Data
public class BaseEntity {
    /**
     * 主键ID
     */
    @Id
    @KeySql(sql = "select SYS_GUID() from dual", order = ORDER.BEFORE)
    protected String id;

    /**
     * 版本号
     */
    @Column(name = "version")
    private Integer version;
}

